/* 日历部分样式 */
.schedule-calendar {
    background: #fff;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.calendar-nav {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nav-btn {
    background: none;
    border: 1px solid #4a90e2;
    color: #4a90e2;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-btn:hover:not(:disabled) {
    background: #4a90e2;
    color: #fff;
}

.nav-btn:disabled {
    border-color: #ccc;
    color: #ccc;
    cursor: not-allowed;
}

.nav-icon {
    font-size: 16px;
    line-height: 1;
}

.date-picker {
    display: flex;
    align-items: center;
    gap: 12px;
}

.today-btn {
    padding: 4px 12px;
    background: #f5f7fa;
    border: 1px solid #dcdfe6;
    color: #606266;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
}

.today-btn:hover {
    background: #ecf5ff;
    color: #4a90e2;
    border-color: #4a90e2;
}

.current-week {
    font-size: 16px;
    color: #333;
    font-weight: 500;
    min-width: 180px;
    text-align: center;
}

.week-range {
    font-size: 16px;
    color: #666;
}

/* 日历网格 */
.calendar-grid {
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
}

.calendar-row {
    display: grid;
    grid-template-columns: 100px repeat(7, 1fr);
}

.calendar-cell {
    padding: 10px;
    text-align: center;
    border-right: 1px solid #eee;
    border-bottom: 1px solid #eee;
    background: #f8f9fa;
}

.day-name {
    font-weight: bold;
    color: #333;
}

.day-date {
    font-size: 14px;
    color: #666;
}

/* 时间段网格 */
.time-grid {
    display: flex;
    flex-direction: column;
}

.time-row {
    display: flex;
    border-bottom: 1px solid #eee;
}

.time-label {
    width: 100px;
    padding: 10px;
    background: #f1f3f4;
    border-right: 1px solid #eee;
    font-size: 14px;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
}

.time-slots {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    flex: 1;
}

.time-slot {
    padding: 10px;
    border-right: 1px solid #eee;
    cursor: pointer;
    transition: all 0.3s;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.time-slot:hover:not(.booked):not(.disabled) {
    background: #e3f2fd;
}

.time-slot.booked {
    background: #e8f5e9;
    cursor: default;
}

.time-slot.disabled {
    background: #f5f5f5;
    cursor: not-allowed;
}

.slot-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.client-name {
    font-weight: bold;
    color: #2e7d32;
}

.consult-type {
    font-size: 12px;
    color: #666;
}

/* 模态框样式 */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    width: 400px;
    max-width: 90%;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #333;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.form-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

.cancel-btn {
    padding: 8px 16px;
    background: #f5f5f5;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.submit-btn {
    padding: 8px 16px;
    background: #4a90e2;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.submit-btn:hover {
    background: #357abd;
}

/* 添加时间标题单元格样式 */
.time-header {
    background: #f1f3f4;
    font-weight: bold;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
}

.schedule-slot {
    padding: 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
}

.schedule-slot.available {
    background-color: #e3f2fd;
    border: 1px solid #90caf9;
}

.schedule-slot.booked {
    background-color: #fff3e0;
    border: 1px solid #ffb74d;
}

.schedule-slot.cancelled {
    background-color: #ffebee;
    border: 1px solid #ef9a9a;
}

.slot-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.slot-type {
    font-size: 12px;
    color: #666;
}

.slot-status {
    font-size: 14px;
    font-weight: 500;
}

.slot-client {
    font-size: 12px;
    color: #333;
}

.empty-slot {
    background-color: #f5f5f5;
    cursor: pointer;
}

.empty-slot:hover {
    background-color: #e0e0e0;
}

/* 表格样式 */
.schedule-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
}

.schedule-table th,
.schedule-table td {
    border: 1px solid #e0e0e0;
    padding: 12px;
    text-align: center;
    vertical-align: middle;
}

.schedule-table th {
    background: #f5f7fa;
    font-weight: 500;
    color: #333;
}

.time-header {
    width: 120px;
    background: #f1f3f4;
}

.time-cell {
    background: #f8f9fa;
    font-weight: 500;
    color: #666;
}

/* 排班状态样式 */
.schedule-slot {
    min-height: 80px;
    padding: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

/* 可预约状态 */
.schedule-slot.available {
    background-color: #e8f5e9;
    border: 1px solid #81c784;
}

.schedule-slot.available .slot-status {
    color: #2e7d32;
}

/* 已预约状态 */
.schedule-slot.booked {
    background-color: #fff3e0;
    border: 1px solid #ffb74d;
}

.schedule-slot.booked .slot-status {
    color: #f57c00;
}

/* 已取消状态 */
.schedule-slot.cancelled {
    background-color: #ffebee;
    border: 1px solid #ef9a9a;
}

.schedule-slot.cancelled .slot-status {
    color: #d32f2f;
}

/* 预约中状态 */
.schedule-slot.pending {
    background-color: #e3f2fd;
    border: 1px solid #64b5f6;
}

.schedule-slot.pending .slot-status {
    color: #1976d2;
}

/* 咨询类型样式 */
.schedule-slot.online .slot-type {
    background-color: #e3f2fd;
    color: #1976d2;
    padding: 2px 6px;
    border-radius: 12px;
    font-size: 12px;
}

.schedule-slot.offline .slot-type {
    background-color: #f3e5f5;
    color: #7b1fa2;
    padding: 2px 6px;
    border-radius: 12px;
    font-size: 12px;
}

/* 单元格内容布局 */
.slot-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
}

.slot-type {
    font-size: 12px;
    margin-bottom: 4px;
}

.slot-status {
    font-weight: 500;
    font-size: 14px;
}

.slot-client {
    font-size: 12px;
    color: #666;
    margin-top: 4px;
}

/* 空单元格样式 */
.empty-slot {
    background-color: #fafafa;
    min-height: 80px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.empty-slot:hover {
    background-color: #f0f0f0;
}

/* 鼠标悬停效果 */
.schedule-slot:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 禁用状态样式 */
.disabled-slot {
    background-color: #f5f5f5;
    cursor: not-allowed;
    opacity: 0.7;
    pointer-events: none;
}

.disabled-slot:hover {
    background-color: #f5f5f5;
    transform: none;
    box-shadow: none;
}

.disabled-slot .slot-content {
    opacity: 0.5;
}

/* 排班表格单元格状态样式 */
.schedule-slot {
    min-height: 80px;
    padding: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
}

/* 可预约状态 - 绿色系 */
.slot-available {
    background-color: #e8f5e9;
    border: 1px solid #c8e6c9;
}

.slot-available:hover {
    background-color: #c8e6c9;
}

/* 已预约状态 - 蓝色系 */
.slot-booked {
    background-color: #e3f2fd;
    border: 1px solid #bbdefb;
    cursor: not-allowed;
}

/* 已取消状态 - 灰色系 */
.slot-cancelled {
    background-color: #f5f5f5;
    border: 1px solid #eeeeee;
    cursor: not-allowed;
}

/* 空白状态 - 浅灰色 */
.slot-empty {
    background-color: #fafafa;
    border: 1px solid #f5f5f5;
}

.slot-empty:hover {
    background-color: #f5f5f5;
}

/* 内容样式 */
.slot-content {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.slot-type {
    font-size: 14px;
    color: #666;
}

.slot-status {
    font-size: 12px;
    font-weight: 500;
}

.slot-client {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}

/* 基础单元格样式 */
.schedule-table td {
    height: 100px;
    padding: 10px;
    vertical-align: top;
    border: 1px solid #e0e0e0;
    position: relative;
}

/* 空单元格样式 */
.slot-empty {
    background-color: #fafafa;
}

/* 可预约状态 */
.slot-available {
    background-color: #e8f5e9 !important;
    border: 1px solid #c8e6c9;
    cursor: pointer !important;
}

.slot-available:hover {
    background-color: #c8e6c9 !important;
}

/* 已预约状态 */
.slot-booked {
    background-color: #e3f2fd !important;
    border: 1px solid #bbdefb;
    cursor: not-allowed !important;
    opacity: 0.8;
}

/* 已取消状态 */
.slot-cancelled {
    background-color: #f5f5f5 !important;
    border: 1px solid #eeeeee;
    cursor: not-allowed !important;
    opacity: 0.8;
}

/* 咨询类型样式 */
.type-online .slot-type {
    color: #1976d2;
}

.type-offline .slot-type {
    color: #7b1fa2;
}

/* 内容布局 */
.slot-content {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
}

.slot-type {
    font-size: 14px;
    font-weight: 500;
}

.slot-status {
    font-size: 12px;
    color: #666;
}

.slot-client {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}

/* 添加状态样式 */
.slot-available {
    background-color: #e8f5e9;
    border: 1px solid #c8e6c9;
}

.slot-booked {
    background-color: #e3f2fd;
    border: 1px solid #bbdefb;
}

.slot-cancelled {
    background-color: #f5f5f5;
    border: 1px solid #eeeeee;
}

.status-text {
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 10px;
}

.status-available {
    color: #388e3c;
    background-color: #e8f5e9;
}

.status-booked {
    color: #1976d2;
    background-color: #e3f2fd;
}

.status-cancelled {
    color: #757575;
    background-color: #f5f5f5;
}

/* 禁用状态下的悬停效果 */
.slot-booked:hover,
.slot-cancelled:hover {
    transform: none !important;
    box-shadow: none !important;
}

/* 可被约状态 */
.slot-selected {
    background-color: #e3f2fd !important;
    border: 1px solid #bbdefb;
    cursor: not-allowed !important;
}

.slot-selected:hover {
    background-color: #e3f2fd !important;
}